package com.ww.aviator.func;

import com.googlecode.aviator.AviatorEvaluator;
import com.googlecode.aviator.Expression;

import java.io.IOException;
import java.net.URL;

public class StaticMethodTest {

    public static void main(String[] args) throws IOException, IllegalAccessException, NoSuchMethodException {
        URL url = FuncTest.class.getClassLoader().getResource("av/func/static_methods.av");
        assert url != null;

        AviatorEvaluator.addInstanceFunctions("s", String.class);

        Expression compile = AviatorEvaluator.getInstance().compileScript(url.getPath());
        compile.execute();
    }
}
